package main

import (
	"fmt"
	"math"
	"unsafe"
)

func main() {
	var i int

	var size = unsafe.Sizeof(i)
	fmt.Printf("int i=%d,size=%d\n", i, size)

	var i8 int8

	size = unsafe.Sizeof(i)
	fmt.Printf("int i8=%d,size=%d\n", i8, size)

	var i16 int16

	size = unsafe.Sizeof(i)
	fmt.Printf("int i16=%d,size=%d\n", i16, size)

	var i32 int32

	size = unsafe.Sizeof(i)
	fmt.Printf("int i32=%d,size=%d\n", i32, size)

	var i64 int64

	size = unsafe.Sizeof(i)
	fmt.Printf("int i64=%d,size=%d\n", i64, size)

	var ui uint

	size = unsafe.Sizeof(i)
	fmt.Printf("int ui=%d,size=%d\n", ui, size)

	var ui8 uint8

	size = unsafe.Sizeof(i)
	fmt.Printf("int ui8=%d,size=%d\n", ui8, size)

	var ui16 uint16

	size = unsafe.Sizeof(i)
	fmt.Printf("int ui16=%d,size=%d\n", ui16, size)

	var ui32 uint32

	size = unsafe.Sizeof(i)
	fmt.Printf("int ui32=%d,size=%d\n", ui32, size)

	var ui64 uint64

	size = unsafe.Sizeof(i)
	fmt.Printf("int ui64=%d,size=%d\n", ui64, size)

	fmt.Printf("int8 min=%d , max=%d \n", math.MinInt8, math.MaxInt8)
	fmt.Printf("int16 min=%d , max=%d \n", math.MinInt16, math.MaxInt16)
	fmt.Printf("int32 min=%d , max=%d \n", math.MinInt32, math.MaxInt32)
	fmt.Printf("int64 min=%d , max=%d \n", math.MinInt64, math.MaxInt64)

	fmt.Printf("uint8 max=%d \n", math.MaxUint8)
	fmt.Printf("uint16 max=%d \n", math.MaxUint16)
	fmt.Printf("uint32 max=%d \n", math.MaxUint32)
	fmt.Printf("uint64 max=%d \n", uint64(math.MaxUint64))
}
